/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * FormRegistrarEquipos.java
 *
 * Created on 10-dic-2011, 22:04:22
 */
package Vista;
import Modelo.Equipos;
import java.awt.event.ActionListener;

/**
 *
 * @author Angge
 */
public class FormRegistrarEquipos extends javax.swing.JFrame {
int posicion=0;

    /** Creates new form FormRegistrarEquipos */
    public FormRegistrarEquipos() {
        initComponents();
 
    }

    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jPanel1 = new javax.swing.JPanel();
        txtjuegosperdidos = new java.awt.TextField();
        txtjuegosganados = new java.awt.TextField();
        txtciudad = new java.awt.TextField();
        txtjuegosjugados = new java.awt.TextField();
        lblnombreestadio = new java.awt.Label();
        lbljuegosjugados = new java.awt.Label();
        lblañofundacion = new java.awt.Label();
        lblciudad = new java.awt.Label();
        jTextFieldanno = new java.awt.TextField();
        lbljuegosganados = new java.awt.Label();
        lbljuegosperdidos = new java.awt.Label();
        txtnombreestadio = new java.awt.TextField();
        lblcodigoequipo = new java.awt.Label();
        txtnombreequipo = new java.awt.TextField();
        lblnombreequipo = new java.awt.Label();
        txtcodigoequipo = new java.awt.TextField();
        jButtongrabar = new javax.swing.JButton();
        jButtoneliminar = new javax.swing.JButton();
        jButtoncancelar = new javax.swing.JButton();
        jButtonconsultar = new javax.swing.JButton();
        jLabel1 = new javax.swing.JLabel();
        jButtonvolver = new javax.swing.JButton();
        jMenuBar1 = new javax.swing.JMenuBar();

        setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
        setTitle("Registrar Datos de Equipos");

        jPanel1.setBorder(javax.swing.BorderFactory.createTitledBorder("Equipos"));
        jPanel1.setCursor(new java.awt.Cursor(java.awt.Cursor.DEFAULT_CURSOR));

        lblnombreestadio.setFont(new java.awt.Font("Arial", 1, 12));
        lblnombreestadio.setText("Nombre del Estadio:");

        lbljuegosjugados.setFont(new java.awt.Font("Arial", 1, 12));
        lbljuegosjugados.setText("Juegos Jugados:");

        lblañofundacion.setFont(new java.awt.Font("Arial", 1, 12));
        lblañofundacion.setText("Año de Fundación: ");

        lblciudad.setFont(new java.awt.Font("Arial", 1, 12));
        lblciudad.setText("Ciudad: ");

        jTextFieldanno.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyTyped(java.awt.event.KeyEvent evt) {
                jTextFieldannoKeyTyped(evt);
            }
        });

        lbljuegosganados.setFont(new java.awt.Font("Arial", 1, 12));
        lbljuegosganados.setText("Juegos Ganados:");

        lbljuegosperdidos.setFont(new java.awt.Font("Arial", 1, 12));
        lbljuegosperdidos.setText("Juegos Perdidos: ");

        lblcodigoequipo.setFont(new java.awt.Font("Arial", 1, 12));
        lblcodigoequipo.setText("Codigo del Equipo:");

        lblnombreequipo.setFont(new java.awt.Font("Arial", 1, 12));
        lblnombreequipo.setText("Nombre del Equipo: ");

        txtcodigoequipo.addFocusListener(new java.awt.event.FocusAdapter() {
            public void focusLost(java.awt.event.FocusEvent evt) {
                txtcodigoequipoFocusLost(evt);
            }
        });
        txtcodigoequipo.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyTyped(java.awt.event.KeyEvent evt) {
                txtcodigoequipoKeyTyped(evt);
            }
        });

        javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
        jPanel1.setLayout(jPanel1Layout);
        jPanel1Layout.setHorizontalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(lblcodigoequipo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(lblnombreequipo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(lblañofundacion, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(lblciudad, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(16, 16, 16)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addComponent(jTextFieldanno, javax.swing.GroupLayout.DEFAULT_SIZE, 150, Short.MAX_VALUE)
                    .addComponent(txtnombreequipo, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(txtcodigoequipo, javax.swing.GroupLayout.DEFAULT_SIZE, 150, Short.MAX_VALUE)
                    .addComponent(txtciudad, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addGap(30, 30, 30)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(lbljuegosjugados, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(lblnombreestadio, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(lbljuegosganados, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(lbljuegosperdidos, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addGap(11, 11, 11)
                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                            .addComponent(txtjuegosperdidos, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                            .addComponent(txtjuegosganados, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                            .addComponent(txtjuegosjugados, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 132, Short.MAX_VALUE)))
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(txtnombreestadio, javax.swing.GroupLayout.DEFAULT_SIZE, 133, Short.MAX_VALUE)))
                .addContainerGap())
        );
        jPanel1Layout.setVerticalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addComponent(lblcodigoequipo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addComponent(txtcodigoequipo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                            .addComponent(txtnombreestadio, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(lblnombreestadio, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))))
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addGap(9, 9, 9)
                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(lblnombreequipo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtjuegosjugados, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(txtjuegosganados, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jTextFieldanno, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(lblañofundacion, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(lbljuegosganados, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addGap(11, 11, 11)
                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(lbljuegosjugados, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtnombreequipo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                            .addComponent(lblciudad, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtciudad, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addGroup(jPanel1Layout.createSequentialGroup()
                            .addGap(1, 1, 1)
                            .addComponent(lbljuegosperdidos, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                    .addComponent(txtjuegosperdidos, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(34, Short.MAX_VALUE))
        );

        jButtongrabar.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Archivos/Floppy-drive-icon1.png"))); // NOI18N
        jButtongrabar.setText("GRABAR");

        jButtoneliminar.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Archivos/Button-Delete-icon1.png"))); // NOI18N
        jButtoneliminar.setText("ELIMINAR");

        jButtoncancelar.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Archivos/Button-Close-icon1.png"))); // NOI18N
        jButtoncancelar.setText("CANCELAR");

        jButtonconsultar.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Archivos/Button-Refresh-icon1.png"))); // NOI18N
        jButtonconsultar.setText("CONSULTAR");

        jLabel1.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Archivos/TituloRegEquipo.png"))); // NOI18N

        jButtonvolver.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Archivos/home-icon1.png"))); // NOI18N
        jButtonvolver.setText("VOLVER");
        setJMenuBar(jMenuBar1);

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabel1, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addGroup(layout.createSequentialGroup()
                        .addGap(48, 48, 48)
                        .addComponent(jButtongrabar, javax.swing.GroupLayout.PREFERRED_SIZE, 123, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jButtoneliminar, javax.swing.GroupLayout.PREFERRED_SIZE, 125, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jButtoncancelar, javax.swing.GroupLayout.PREFERRED_SIZE, 128, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jButtonconsultar)))
                .addContainerGap())
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                .addContainerGap(415, Short.MAX_VALUE)
                .addComponent(jButtonvolver)
                .addGap(130, 130, 130))
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(36, Short.MAX_VALUE))
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                .addComponent(jLabel1)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 27, Short.MAX_VALUE)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jButtongrabar, javax.swing.GroupLayout.PREFERRED_SIZE, 38, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jButtoneliminar)
                    .addComponent(jButtoncancelar)
                    .addComponent(jButtonconsultar))
                .addGap(29, 29, 29)
                .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(50, 50, 50)
                .addComponent(jButtonvolver)
                .addGap(84, 84, 84))
        );

        java.awt.Dimension screenSize = java.awt.Toolkit.getDefaultToolkit().getScreenSize();
        setBounds((screenSize.width-657)/2, (screenSize.height-518)/2, 657, 518);
    }// </editor-fold>//GEN-END:initComponents

private void jTextFieldannoKeyTyped(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldannoKeyTyped
 String datos;
    
    datos = jTextFieldanno.getText();
    
    char caracter = evt.getKeyChar();
    if(caracter < '0' || caracter > '9' )
        evt.consume();
    else
        if(datos.length()==4)
            evt.consume();
}//GEN-LAST:event_jTextFieldannoKeyTyped

private void txtcodigoequipoKeyTyped(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_txtcodigoequipoKeyTyped
// TODO add your handling code here:
     String datos;
    
    datos = txtcodigoequipo.getText();
    
    char caracter = evt.getKeyChar();
    if(caracter < '0' || caracter > '9' )
        evt.consume();
    else
        if(datos.length()==2)
            evt.consume();
}//GEN-LAST:event_txtcodigoequipoKeyTyped

private void txtcodigoequipoFocusLost(java.awt.event.FocusEvent evt) {//GEN-FIRST:event_txtcodigoequipoFocusLost
// TODO add your handling code here:
    int Posi=0;
          Equipos equipo;

    Posi=Equipos.ExisteEquipo(txtcodigoequipo.getText());
    
    if (Posi>=0)
      {  
        equipo = Equipos.ListaEquipos.get(Posi); 
        String juegosjugados= String.valueOf(equipo.getJJ());
        String juegosganados= String.valueOf(equipo.getJG());
        String juegosperdidos= String.valueOf(equipo.getJP());
        txtnombreequipo.setText(equipo.getNombEquipo());
        jTextFieldanno.setText(equipo.getAnoFund());
        txtciudad.setText(equipo.getCiudad());
        txtnombreestadio.setText(equipo.getNombEstadio());
        txtjuegosjugados.setText(juegosjugados);
        txtjuegosganados.setText(juegosganados);
        txtjuegosperdidos.setText(juegosperdidos);
       txtnombreequipo.enable(false);
        jTextFieldanno.enable(false);
        txtciudad.enable(false);
        txtnombreestadio.enable(false);
        txtjuegosjugados.enable(false);
        txtjuegosganados.enable(false);
        txtjuegosganados.enable(false);
        
      }
   posicion=Posi;
        
}//GEN-LAST:event_txtcodigoequipoFocusLost
                                    

public void btnGrabar() {                                           
String datos;

 datos = txtcodigoequipo.getText();
 if(datos.length()==0)
 {
     Mensajes.Aviso("Codigo vacio", "Equipos");
     txtcodigoequipo.requestFocusInWindow();
     return;
 }
   datos = txtnombreequipo.getText();
   if (datos.length()==0)
   {
      Mensajes.Aviso("Nombre vacio", "Equipos");
       txtnombreequipo.requestFocusInWindow();
       return;
   }
  datos = jTextFieldanno.getText();
  if(datos.length()==0)
  {
      Mensajes.Aviso("Seleccione el Año", "Equipos");
       jTextFieldanno.requestFocusInWindow();
       return;

  }
    datos = txtciudad.getText();
     if(datos.length()==0)
     {
         Mensajes.Aviso("Ciudad Vacia", "Equipos");
         txtciudad.requestFocusInWindow();
         return;
     }
  datos = txtnombreestadio.getText();
  if(datos.length()==0)
  {
      Mensajes.Aviso("Nombre De Estadio Vacio", "Equipos");
      txtnombreestadio.requestFocusInWindow();
      return;
  }
    datos = txtjuegosjugados.getText();
    if(datos.length()==0)
    {
        Mensajes.Aviso("Ingrese Los Juegos Jugados", "Equipos");
        txtjuegosjugados.requestFocusInWindow();
        return;
    }
  datos = txtjuegosganados.getText();
  if(datos.length()==0)
  {
      Mensajes.Aviso("Ingrese Los juegos Ganados" , "Equipos");
      txtjuegosganados.requestFocusInWindow();
      return;
 }
   datos  = txtjuegosperdidos.getText();
 if(datos.length()==0)
 {
     Mensajes.Aviso("Ingrese Los Juegos Perdidos" , "Equipos");
     txtjuegosperdidos.requestFocusInWindow();
     return;
 }
      
   Equipos.addEquipo(txtcodigoequipo.getText(),txtnombreequipo.getText(),
                       jTextFieldanno.getText(),txtciudad.getText(),
                       txtnombreestadio.getText(),0,0,0);
                        
                        

  btnCancelar();
  Mensajes.Informacion("El Equipo ha sido Guardado", "Informacion");
} 
public void btnEliminar(){
   Equipos.ListaEquipos.remove(posicion);
   Mensajes.Informacion("Equipo Eliminado", "Informacion");
  
}
                                             
public void btnCancelar(){
   txtcodigoequipo.setText("");
  txtnombreequipo.setText("");
  txtciudad.setText("");
  txtnombreestadio.setText("");
  txtjuegosjugados.setText("");
  txtjuegosganados.setText("");
  txtjuegosperdidos.setText("");
  jTextFieldanno.setText("");
  txtcodigoequipo.requestFocusInWindow(); 
}       
    
public void AddListener (ActionListener listener)  
{
    jButtoncancelar.addActionListener(listener);
    jButtonconsultar.addActionListener(listener);
    jButtoneliminar.addActionListener(listener);
    jButtongrabar.addActionListener(listener);
    jButtonvolver.addActionListener(listener);
    
}/**
     * @param args the command line arguments
     */
    public static void main(String args[]) {
        /* Set the Nimbus look and feel */
        //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
        /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
         * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html 
         */
        try {
            for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
                if ("Nimbus".equals(info.getName())) {
                    javax.swing.UIManager.setLookAndFeel(info.getClassName());
                    break;
                }
            }
        } catch (ClassNotFoundException ex) {
            java.util.logging.Logger.getLogger(FormRegistrarEquipos.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (InstantiationException ex) {
            java.util.logging.Logger.getLogger(FormRegistrarEquipos.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (IllegalAccessException ex) {
            java.util.logging.Logger.getLogger(FormRegistrarEquipos.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (javax.swing.UnsupportedLookAndFeelException ex) {
            java.util.logging.Logger.getLogger(FormRegistrarEquipos.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        }
        //</editor-fold>

        /* Create and display the form */
        java.awt.EventQueue.invokeLater(new Runnable() {

            public void run() {
                new FormRegistrarEquipos().setVisible(true);
            }
        });
    }
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton jButtoncancelar;
    private javax.swing.JButton jButtonconsultar;
    private javax.swing.JButton jButtoneliminar;
    private javax.swing.JButton jButtongrabar;
    private javax.swing.JButton jButtonvolver;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JMenuBar jMenuBar1;
    private javax.swing.JPanel jPanel1;
    private java.awt.TextField jTextFieldanno;
    private java.awt.Label lblañofundacion;
    private java.awt.Label lblciudad;
    private java.awt.Label lblcodigoequipo;
    private java.awt.Label lbljuegosganados;
    private java.awt.Label lbljuegosjugados;
    private java.awt.Label lbljuegosperdidos;
    private java.awt.Label lblnombreequipo;
    private java.awt.Label lblnombreestadio;
    private java.awt.TextField txtciudad;
    private java.awt.TextField txtcodigoequipo;
    private java.awt.TextField txtjuegosganados;
    private java.awt.TextField txtjuegosjugados;
    private java.awt.TextField txtjuegosperdidos;
    private java.awt.TextField txtnombreequipo;
    private java.awt.TextField txtnombreestadio;
    // End of variables declaration//GEN-END:variables

   
}
